<template>
    <view :style="themeColor">
        <view class="page" >
    <view class="flex benben-position-layout flex flex-wrap align-center creditScore_flex_0"    :style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
            <view   class='flex flex-wrap align-center justify-between flex-sub creditScore_fd0_0'      >
            <view   class='flex flex-wrap align-center creditScore_fd0_0_c0'   @tap.stop="handleJumpDiy" data-type="back" data-url="1"   >
        <text class='fu-iconfont2  creditScore_fd0_0_c0_c0'    >&#xE794;</text>
</view>
    <view   class='flex flex-wrap align-stretch justify-center'      >
        <text class='creditScore_fd0_0_c1_c0'  >信用分</text>
</view>
    <view   class='flex flex-wrap align-center justify-end creditScore_fd0_0_c0'      >
        </view>
</view>

        </view>
<view :style="{height: (88+StatusBarRpx)+'rpx'}"  ></view>
<!---flex布局flex布局开始-->
 <view class="flex flex-direction flex-wrap align-stretch benben-flex-layout creditScore_flex_1"    >
        <text class='creditScore_fd1_0'  >{{userData.credit_score}}</text>
    <view   class='flex flex-wrap align-center creditScore_fd1_1'      >
        <text class='creditScore_fd1_1_c0'  >总信用分</text>
<text class='fu-iconfont2  creditScore_fd1_1_c1'   @tap="handleJumpDiy" data-type="navigateTo" :data-url="`/pages/wode/credit/credit`" >&#xe67c;</text>
</view>
</view>
        
<!---flex布局flex布局结束-->
<!---flex布局flex布局开始-->
 <view class="flex flex-direction flex-wrap align-stretch benben-flex-layout creditScore_flex_2"    >
        <text class='creditScore_fd2_0'  >信用分记录</text>
    <template v-for = '(item,key0) in integralRecord'>
    <view   class='flex flex-direction flex-wrap align-stretch justify-between creditScore_fd2_1'       :key='key0'>
            <view   class='flex flex-wrap align-center justify-between'      >
        <text class='flex-sub creditScore_fd2_1_c0_c0'  >{{item.user_nickname}}</text>
<text class='creditScore_fd2_1_c0_c1'    v-if= " item.chang_type=='1'"  >{{item.credit_score}}</text><text class='creditScore_fd2_1_c0_c1_1'    v-if= " item.chang_type=='2'"  >{{item.credit_score}}</text>
</view>
<text class='creditScore_fd2_1_c1'  >{{item.create_time}}</text>
</view>
    </template>
    <fu-empty :pagingListLoadedAll="pagingListLoadedAll" :pagingListNoListData="pagingListNoListData" :listDataLength="listDataLength" :isLoadInit="isLoadInit"></fu-empty>
</view>
        
<!---flex布局flex布局结束-->
    
    
        </view>
    </view>
</template>
<script>
    import pagingList from '@/common/mixin/paging_list.js';
import {validate} from '@/common/utils/validate.js'
    
    export default {
        components:{},
        mixins: [pagingList],
        
        data(){
			return {"minixPagingListsApi":"","pageingListApiMethod":"","allowOnloadGetList":false,"integralRecord":[],"userData":{"invite_code":"","address":"","address_code":"","hobby":"","tags":"","id":"","userlevel_id":"","mobile":"","real_name":"","nickname":"","avatar":"","account":"","email":"","birthday":"","gender":"","create_time":"","user_money":"","freeze_money":"","total_consumption_money":"","score":"","_mobile":"","coupon":"","collection_count":"","browse_count":"","total_money":"","certified":"","is_pay_password":"","fuwuxingji":"","gongzuozhuangtai":"","shuzi":"","jifen":"","yajin":"","level":{"aid":"","name":"","icon":"","levelid":""},"invite_num":"","commission":"","is_deposit":"","is_account":"","dengjidaoqishijian":"","suozaidi":"","huiyuanyue":"","working_hours":"","credit_score":"","deposit":""}};
		},
		computed:{
            themeColor() {
              return this.$store.getters.themeColor
            },
                          userInfo: {
      get() {
        return this.$store.state.userInfo
      },
      set() {
        this.$store.commit('updateUserInfo', value)
      },
    }
		},
		watch:{},
		onLoad(options){
            this.getIntegralRecordFunc()
this.getUserFunc()
		},
        onUnload() {
                
        },
		onReady(){
            
		},
		onShow(){
            
		},
		onHide(){
            
		},
		onResize(){
            
		},
		onPullDownRefresh(){
            
		},
		onReachBottom(e){
            
		},
		onPageScroll(e){
            
		},
		methods:{
                            //获取信用分记录
                 getIntegralRecordFunc(){
                                    this.minixPagingListsApi = global.apiUrls.post64e318659e410;
                this.pageingListApiMethod = 'get';
                this.allowOnloadGetList = false;
                this.pagingListPostDataContent = {}
                this.listData = [];
                this.integralRecord = this.listData;
                this.pagingListToggle();
                
                },
                //获取会员信息
                async getUserFunc(){
                        //请求方法
    //数据验证
    
  let datauserData = await this.$api.get(global.apiUrls.post5c78c4772da97, {
    user_id:this.userInfo.id
  });
  
  if (datauserData.data.code != 1) {
    this.$message.info(datauserData.data.msg);
    return
  } 
  let infouserData = datauserData.data;
  this.userData = infouserData.data
  
                },
                pagingListPostData(){
                    return this.pagingListPostDataContent
                }
		}
    };
</script> 
<style lang="scss" scoped>
           .page{
            width: 100vw;
            overflow-x: hidden;
            min-height: calc(100vh - var(--window-bottom));
            background:url(image-path('151.png')) no-repeat;background-size: 100% auto;
        }
    .creditScore_flex_0{
        background:url(image-path('151.png')) no-repeat;width:750rpx;height:88rpx;overflow:hidden;z-index:10;top:0rpx;background-size:100% auto !important;
    }
    .creditScore_fd0_0_c1_c0{
        font-size:36rpx;font-weight:500;color:rgba(255, 255, 255, 1);line-height:88rpx;
    }
    .creditScore_fd0_0_c0_c0{
        font-size:36rpx;color:rgba(255, 255, 255, 1);
    }
    .creditScore_fd0_0_c0{
        width:120rpx;height:88rpx;
    }
    .creditScore_fd0_0{
        padding:0rpx 32rpx 0rpx 32rpx;height:88rpx;
    }
    .creditScore_flex_1{
        padding:48rpx 64rpx 38rpx 64rpx;
    }
    .creditScore_fd1_1_c1{
        font-size:28rpx;color:rgba(255, 255, 255, 1);
    }
    .creditScore_fd1_1_c0{
        color:#FFFFFF;font-size:28rpx;font-weight:500;line-height:40rpx;margin:0rpx 16rpx 0rpx 0rpx;
    }
    .creditScore_fd1_1{
        margin:8rpx 0rpx 0rpx 0rpx;
    }
    .creditScore_fd1_0{
        color:#FFFFFF;font-size:64rpx;font-weight:700;line-height:77rpx;
    }
    .creditScore_flex_2{
        background:rgba(255, 255, 255, 1);margin:0rpx 24rpx 0rpx 24rpx;background-size:100% auto;border-radius:16rpx;padding:42rpx 32rpx 0rpx 32rpx;
    }
    .creditScore_fd2_1_c1{
        margin:16rpx 0rpx 0rpx 0rpx;color:#999999;font-size:24rpx;font-weight:400;line-height:33rpx;
    }
    .creditScore_fd2_1_c0_c1_1{
        color:rgba(51, 51, 51, 1);font-size:32rpx;font-weight:700;line-height:40rpx;
    }
    .creditScore_fd2_1_c0_c1{
        color:#FF5050;font-size:32rpx;font-weight:700;line-height:40rpx;
    }
    .creditScore_fd2_1_c0_c0{
        color:#333333;font-size:28rpx;margin:0rpx 24rpx 0rpx 0rpx;-webkit-line-clamp:1;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical;font-weight:400;line-height:40rpx;
    }
    .creditScore_fd2_1{
        border-bottom:1px solid #eee;padding:32rpx 0rpx 32rpx 0rpx;
    }
    .creditScore_fd2_0{
        font-weight:700;font-size:32rpx;color:#333333;line-height:45rpx;
    }
</style>